on:
  push:
    branches:
      - master
  pull_request:
    branches: '*'

name: Project check
jobs:
  check:
    name: Check
    runs-on: ubuntu-latest
    steps:
    - name: Set up Node.js
      uses: actions/setup-node@v3
      with:
        node-version: '18'

    - uses: actions/checkout@master
      name: Checkout

    - name: Install dependencies
      run: npm install

    - name: Run checks
      run: npm test && npm run lint
